<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Class template format_date_parser</title>
<link rel="stylesheet" href="../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
<link rel="up" href="../../date_time/doxy.html#header.boost.date_time.format_date_parser_hpp" title="Header &lt;boost/date_time/format_date_parser.hpp&gt;">
<link rel="prev" href="find_match.html" title="Function template find_match">
<link rel="next" href="fixed_1_3_14_15_3_27_2_1_2.html" title="Function template fixed_string_to_int">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../boost.png"></td>
<td align="center"><a href="../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="find_match.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../date_time/doxy.html#header.boost.date_time.format_date_parser_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="fixed_1_3_14_15_3_27_2_1_2.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.date_time.format_date_parser"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Class template format_date_parser</span></h2>
<p>boost::date_time::format_date_parser — Class with generic date parsing using a format string. </p>
</div>
<h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2>
<div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../date_time/doxy.html#header.boost.date_time.format_date_parser_hpp" title="Header &lt;boost/date_time/format_date_parser.hpp&gt;">boost/date_time/format_date_parser.hpp</a>&gt;

</span><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> date_type<span class="special">,</span> <span class="keyword">typename</span> charT<span class="special">&gt;</span> 
<span class="keyword">class</span> <a class="link" href="format_date_parser.html" title="Class template format_date_parser">format_date_parser</a> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
  <span class="comment">// types</span>
  <span class="keyword">typedef</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span>                <a name="boost.date_time.format_date_parser.string_type"></a><span class="identifier">string_type</span><span class="special">;</span>          
  <span class="keyword">typedef</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_istringstream</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span>         <a name="boost.date_time.format_date_parser.stringstream_type"></a><span class="identifier">stringstream_type</span><span class="special">;</span>    
  <span class="keyword">typedef</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span>         <a name="boost.date_time.format_date_parser.stream_itr_type"></a><span class="identifier">stream_itr_type</span><span class="special">;</span>      
  <span class="keyword">typedef</span> <span class="identifier">string_type</span><span class="special">::</span><span class="identifier">const_iterator</span>               <a name="boost.date_time.format_date_parser.const_itr"></a><span class="identifier">const_itr</span><span class="special">;</span>            
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">year_type</span>                      <a name="boost.date_time.format_date_parser.year_type"></a><span class="identifier">year_type</span><span class="special">;</span>            
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">month_type</span>                     <a name="boost.date_time.format_date_parser.month_type"></a><span class="identifier">month_type</span><span class="special">;</span>           
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">day_type</span>                       <a name="boost.date_time.format_date_parser.day_type"></a><span class="identifier">day_type</span><span class="special">;</span>             
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">duration_type</span>                  <a name="boost.date_time.format_date_parser.duration_type"></a><span class="identifier">duration_type</span><span class="special">;</span>        
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">day_of_week_type</span>               <a name="boost.date_time.format_date_parser.day_of_week_type"></a><span class="identifier">day_of_week_type</span><span class="special">;</span>     
  <span class="keyword">typedef</span> <span class="identifier">date_type</span><span class="special">::</span><span class="identifier">day_of_year_type</span>               <a name="boost.date_time.format_date_parser.day_of_year_type"></a><span class="identifier">day_of_year_type</span><span class="special">;</span>     
  <span class="keyword">typedef</span> <a class="link" href="string_parse_tree.html" title="Struct template string_parse_tree">string_parse_tree</a><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span>                <a name="boost.date_time.format_date_parser.parse_tree_type"></a><span class="identifier">parse_tree_type</span><span class="special">;</span>      
  <span class="keyword">typedef</span> parse_tree_type::parse_match_result_type  <a name="boost.date_time.format_date_parser.match_results"></a><span class="identifier">match_results</span><span class="special">;</span>        
  <span class="keyword">typedef</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special">&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_string</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&gt;</span> <a name="boost.date_time.format_date_parser.input_collection_type"></a><span class="identifier">input_collection_type</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="format_date_parser.html#boost.date_time.format_date_parserconstruct-copy-destruct">construct/copy/destruct</a></span>
  <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_18-bb"><span class="identifier">format_date_parser</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">,</span> 
                     <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">,</span> 
                     <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">,</span> 
                     <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_19-bb"><span class="identifier">format_date_parser</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">locale</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_20-bb"><span class="identifier">format_date_parser</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="format_date_parser.html" title="Class template format_date_parser">format_date_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17-bb">public member functions</a></span>
  <span class="identifier">string_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_1-bb"><span class="identifier">format</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">void</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_2-bb"><span class="identifier">format</span></a><span class="special">(</span><span class="identifier">string_type</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">void</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_3-bb"><span class="identifier">short_month_names</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">void</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_4-bb"><span class="identifier">long_month_names</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">void</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_5-bb"><span class="identifier">short_weekday_names</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">void</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_6-bb"><span class="identifier">long_weekday_names</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
  <span class="identifier">date_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_7-bb"><span class="identifier">parse_date</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">date_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_8-bb"><span class="identifier">parse_date</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">date_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_9-bb"><span class="identifier">parse_date</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">,</span> 
                       <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">month_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_10-bb"><span class="identifier">parse_month</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                         <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">month_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_11-bb"><span class="identifier">parse_month</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                         <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">,</span> 
                         <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">day_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_12-bb"><span class="identifier">parse_var_day_of_month</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                                  <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">day_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_13-bb"><span class="identifier">parse_day_of_month</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                              <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">day_of_week_type</span> 
  <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_14-bb"><span class="identifier">parse_weekday</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">day_of_week_type</span> 
  <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_15-bb"><span class="identifier">parse_weekday</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">,</span> 
                <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">year_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_16-bb"><span class="identifier">parse_year</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="identifier">year_type</span> <a class="link" href="format_date_parser.html#id-1_3_14_15_3_27_2_1_1_17_17-bb"><span class="identifier">parse_year</span></a><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">string_type</span><span class="special">,</span> 
                       <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="id-1.3.14.15.3.27.3.4"></a><h2>Description</h2>
<p>The following is the set of recognized format specifiers</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem"><p>a - Short weekday name</p></li>
<li class="listitem"><p>A - Long weekday name</p></li>
<li class="listitem"><p>b - Abbreviated month name</p></li>
<li class="listitem"><p>B - Full month name</p></li>
<li class="listitem"><p>d - Day of the month as decimal 01 to 31</p></li>
<li class="listitem"><p>j - Day of year as decimal from 001 to 366</p></li>
<li class="listitem"><p>m - Month name as a decimal 01 to 12</p></li>
<li class="listitem"><p>U - Week number 00 to 53 with first Sunday as the first day of week 1?</p></li>
<li class="listitem"><p>w - Weekday as decimal number 0 to 6 where Sunday == 0</p></li>
<li class="listitem"><p>W - Week number 00 to 53 where Monday is first day of week 1</p></li>
<li class="listitem"><p>x - facet default date representation</p></li>
<li class="listitem"><p>y - Year without the century - eg: 04 for 2004</p></li>
<li class="listitem"><p>Y - Year with century</p></li>
</ul></div>
<p>
</p>
<p>The weekday specifiers (a and A) do not add to the date construction, but they provide a way to skip over the weekday names for formats that provide them.</p>
<p>todo – Another interesting feature that this approach could provide is an option to fill in any missing fields with the current values from the clock. So if you have m-d the parser would detect the missing year value and fill it in using the clock.</p>
<p>todo – What to do with the x. x in the classic facet is just bad... </p>
<div class="refsect2">
<a name="id-1.3.14.15.3.27.3.4.6"></a><h3>
<a name="boost.date_time.format_date_parserconstruct-copy-destruct"></a><code class="computeroutput">format_date_parser</code> 
        public
       construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem"><pre class="literallayout"><a name="id-1_3_14_15_3_27_2_1_1_18-bb"></a><span class="identifier">format_date_parser</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span> format_str<span class="special">,</span> 
                   <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> month_short_names<span class="special">,</span> 
                   <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> month_long_names<span class="special">,</span> 
                   <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> weekday_short_names<span class="special">,</span> 
                   <span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> weekday_long_names<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><a name="id-1_3_14_15_3_27_2_1_1_19-bb"></a><span class="identifier">format_date_parser</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span> format_str<span class="special">,</span> <span class="keyword">const</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">locale</span> <span class="special">&amp;</span> locale<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><a name="id-1_3_14_15_3_27_2_1_1_20-bb"></a><span class="identifier">format_date_parser</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="format_date_parser.html" title="Class template format_date_parser">format_date_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> fdp<span class="special">)</span><span class="special">;</span></pre></li>
</ol></div>
</div>
<div class="refsect2">
<a name="id-1.3.14.15.3.27.3.4.7"></a><h3>
<a name="id-1_3_14_15_3_27_2_1_1_17-bb"></a><code class="computeroutput">format_date_parser</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem"><pre class="literallayout"><span class="identifier">string_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_1-bb"></a><span class="identifier">format</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">void</span> <a name="id-1_3_14_15_3_27_2_1_1_17_2-bb"></a><span class="identifier">format</span><span class="special">(</span><span class="identifier">string_type</span> format_str<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">void</span> <a name="id-1_3_14_15_3_27_2_1_1_17_3-bb"></a><span class="identifier">short_month_names</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> month_names<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">void</span> <a name="id-1_3_14_15_3_27_2_1_1_17_4-bb"></a><span class="identifier">long_month_names</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> month_names<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">void</span> <a name="id-1_3_14_15_3_27_2_1_1_17_5-bb"></a><span class="identifier">short_weekday_names</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> weekday_names<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">void</span> <a name="id-1_3_14_15_3_27_2_1_1_17_6-bb"></a><span class="identifier">long_weekday_names</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">input_collection_type</span> <span class="special">&amp;</span> weekday_names<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="identifier">date_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_7-bb"></a><span class="identifier">parse_date</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span> value<span class="special">,</span> 
                     <span class="keyword">const</span> <span class="identifier">string_type</span> <span class="special">&amp;</span> format_str<span class="special">,</span> 
                     <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sv_parser<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="identifier">date_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_8-bb"></a><span class="identifier">parse_date</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                     <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                     <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sv_parser<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">date_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_9-bb"></a><span class="identifier">parse_date</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                     <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                     <span class="identifier">string_type</span> format_str<span class="special">,</span> 
                     <span class="keyword">const</span> <a class="link" href="special_values_parser.html" title="Class template special_values_parser">special_values_parser</a><span class="special">&lt;</span> <span class="identifier">date_type</span><span class="special">,</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sv_parser<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<p>Of all the objects that the <code class="computeroutput"><a class="link" href="format_date_parser.html" title="Class template format_date_parser">format_date_parser</a></code> can parse, only a date can be a special value. Therefore, only parse_date checks for special_values. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">month_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_10-bb"></a><span class="identifier">parse_month</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                       <span class="identifier">string_type</span> format_str<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Throws bad_month if unable to parse. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">month_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_11-bb"></a><span class="identifier">parse_month</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                       <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                       <span class="identifier">string_type</span> format_str<span class="special">,</span> <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span> mr<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Throws bad_month if unable to parse. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">day_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_12-bb"></a><span class="identifier">parse_var_day_of_month</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                                <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Expects 1 or 2 digits 1-31. Throws bad_day_of_month if unable to parse. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">day_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_13-bb"></a><span class="identifier">parse_day_of_month</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                            <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Expects 2 digits 01-31. Throws bad_day_of_month if unable to parse. </li>
<li class="listitem"><pre class="literallayout"><span class="identifier">day_of_week_type</span> 
<a name="id-1_3_14_15_3_27_2_1_1_17_14-bb"></a><span class="identifier">parse_weekday</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
              <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
              <span class="identifier">string_type</span> format_str<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="identifier">day_of_week_type</span> 
<a name="id-1_3_14_15_3_27_2_1_1_17_15-bb"></a><span class="identifier">parse_weekday</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
              <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
              <span class="identifier">string_type</span> format_str<span class="special">,</span> <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span> mr<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">year_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_16-bb"></a><span class="identifier">parse_year</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                     <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                     <span class="identifier">string_type</span> format_str<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>throws bad_year if unable to parse </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">year_type</span> <a name="id-1_3_14_15_3_27_2_1_1_17_17-bb"></a><span class="identifier">parse_year</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> sitr<span class="special">,</span> 
                     <span class="identifier">std</span><span class="special">::</span><span class="identifier">istreambuf_iterator</span><span class="special">&lt;</span> <span class="identifier">charT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> stream_end<span class="special">,</span> 
                     <span class="identifier">string_type</span> format_str<span class="special">,</span> <a class="link" href="format_date_parser.html#boost.date_time.format_date_parser.match_results">match_results</a> <span class="special">&amp;</span> mr<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>throws bad_year if unable to parse </li>
</ol></div>
</div>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2001-2005 CrystalClear Software, Inc<p>Subject to the Boost Software License, Version 1.0. (See accompanying file
    <code class="filename">LICENSE_1_0.txt</code> or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="find_match.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../date_time/doxy.html#header.boost.date_time.format_date_parser_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="fixed_1_3_14_15_3_27_2_1_2.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
